<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>js document</title>
		<script>
			function changeT(){
				alert(window.document.URL);
				alert(window.document.referrer);
				window.document.title=window.prompt("请输入新标题");
			}
		</script>
	</head>
	<body>
		<button type="button" onclick="changeT()">换标题</button>
	</body>
</html>